﻿using System;
using System.Text;
using System.Collections.Generic;
using System.Linq;
using Microsoft.VisualStudio.TestTools.UnitTesting;

namespace Arcana.Contract.Tests.Argument.Is.Not.GreaterEqual
{
    [TestClass]
    public class ThanAttributeTest
    {
        [Arcana.Contract.Argument.Is.Not.GreaterEqual.Than("param", 6)]
        public static void Target_1(int param)
        {
        }

        [TestMethod]
        [Owner("arcane_master")]
        [WorkItem(48)]
        [ExpectedException(typeof(ArgumentException))]
        public void ShouldThrowException_1()
        {
            Target_1(6);
        }

        [TestMethod]
        [Owner("arcane_master")]
        [WorkItem(48)]
        [ExpectedException(typeof(ArgumentException))]
        public void ShouldThrowException_2()
        {
            Target_1(7);
        }

        [TestMethod]
        [Owner("arcane_master")]
        [WorkItem(48)]
        public void ShouldPass()
        {
            Target_1(5);
            Target_1(0);
        }
    }
}
